package org.polyforms.repository.spi;

import javax.persistence.Query;

/**
 * Helper for resolving parameters of query.
 * 
 * @author Kuisong Tong
 * @since 1.0
 */
public interface QueryParameterResolver {
    /**
     * Get named parameters in JPA query.
     */
    Parameter[] getNamedParameters(Query query);

    /**
     * Type for query parameter objects.
     */
    interface Parameter {
        /**
         * Name of query parameter.
         */
        String name();
    }
}
